<?php
/*
 * [JINYUN!] (C)2001-2099 Jinyunweb.com
 * This is NOT a freeware, use is subject to license terms
 * $Id: 2017-12-13 03:39:35 apple $
*/
defined('BY_JYA') or exit('error');
$_RQ['op']=$_RQ['op']?$_RQ['op']:'main';
$return=array();
if($_RQ['op']=='main'){
	$return['list']=array();
	$return['params']['type']=1;
	exi($return);
}
if($_RQ['op']=='list'){
	$return['ispay']=array('0'=>'待支付','1'=>'已支付','2'=>'支付失败');
	$return['status']=array('0'=>'待审核','1'=>'已发送','2'=>'发送失败');
	$params=array('uniacid'=>$_SESSION['uniacid'],'mid'=>$_SESSION['uid']);
	$pindex = max(1, intval($_RQ['page']));
	$psize = 10;
	$list=pdo_getslice('jy_aihire_fabulog',$params,array($pindex,$psize),$total,array(),'','id desc');
	if($list){
		foreach($list as &$item){
			$pitem=pdo_get('jy_aihire_item',array('uniacid'=>$_SESSION['uniacid'],'id'=>$item['itemid']));
			$item['ptitle']=$pitem['title'];
			$item['paytitle']=$return['ispay'][$item['ispay']];
			$item['statustitle']=$return['status'][$item['status']];
			$item['createtime']=date('Y/m/d H:i:s',$item['createtime']);
		}
	}
	$return['list']=$list?$list:array();
	exi($return);
}